3.79 \(\int \frac{\sin (c+d x)}{(a+a \sec (c+d x))^2} \, dx\)

Optimal. Leaf size=52 \[ -\frac{\cos (c+d x)}{a^2 d}+\frac{1}{d \left (a^2 \cos (c+d x)+a^2\right )}+\frac{2 \log (\cos (c+d x)+1)}{a^2 d} \]

[Out]

-(Cos[c + d*x]/(a^2*d)) + 1/(d*(a^2 + a^2*Cos[c + d*x])) + (2*Log[1 + Cos[c + d*x]])/(a^2*d)

________________________________________________________________________________________

Rubi [A]  time = 0.102093, antiderivative size = 52, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 19, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.21, Rules used = {3872, 2833, 12, 43} \[ -\frac{\cos (c+d x)}{a^2 d}+\frac{1}{d \left (a^2 \cos (c+d x)+a^2\right )}+\frac{2 \log (\cos (c+d x)+1)}{a^2 d} \]

Antiderivative was successfully verified.

[In]

Int[Sin[c + d*x]/(a + a*Sec[c + d*x])^2,x]

[Out]

-(Cos[c + d*x]/(a^2*d)) + 1/(d*(a^2 + a^2*Cos[c + d*x])) + (2*Log[1 + Cos[c + d*x]])/(a^2*d)

Rule 3872

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.), x_Symbol] :> Int[((g*C
os[e + f*x])^p*(b + a*Sin[e + f*x])^m)/Sin[e + f*x]^m, x] /; FreeQ[{a, b, e, f, g, p}, x] && IntegerQ[m]

Rule 2833

Int[cos[(e_.) + (f_.)*(x_)]*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)
])^(n_.), x_Symbol] :> Dist[1/(b*f), Subst[Int[(a + x)^m*(c + (d*x)/b)^n, x], x, b*Sin[e + f*x]], x] /; FreeQ[
{a, b, c, d, e, f, m, n}, x]

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int \frac{\sin (c+d x)}{(a+a \sec (c+d x))^2} \, dx &=\int \frac{\cos ^2(c+d x) \sin (c+d x)}{(-a-a \cos (c+d x))^2} \, dx\\ &=\frac{\operatorname{Subst}\left (\int \frac{x^2}{a^2 (-a+x)^2} \, dx,x,-a \cos (c+d x)\right )}{a d}\\ &=\frac{\operatorname{Subst}\left (\int \frac{x^2}{(-a+x)^2} \, dx,x,-a \cos (c+d x)\right )}{a^3 d}\\ &=\frac{\operatorname{Subst}\left (\int \left (1+\frac{a^2}{(a-x)^2}-\frac{2 a}{a-x}\right ) \, dx,x,-a \cos (c+d x)\right )}{a^3 d}\\ &=-\frac{\cos (c+d x)}{a^2 d}+\frac{1}{d \left (a^2+a^2 \cos (c+d x)\right )}+\frac{2 \log (1+\cos (c+d x))}{a^2 d}\\ \end{align*}

Mathematica [A]  time = 0.184668, size = 64, normalized size = 1.23 \[ -\frac{\sec ^2\left (\frac{1}{2} (c+d x)\right ) \left (\cos (2 (c+d x))-8 \cos (c+d x) \log \left (\cos \left (\frac{1}{2} (c+d x)\right )\right )-8 \log \left (\cos \left (\frac{1}{2} (c+d x)\right )\right )-3\right )}{4 a^2 d} \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[c + d*x]/(a + a*Sec[c + d*x])^2,x]

[Out]

-((-3 + Cos[2*(c + d*x)] - 8*Log[Cos[(c + d*x)/2]] - 8*Cos[c + d*x]*Log[Cos[(c + d*x)/2]])*Sec[(c + d*x)/2]^2)
/(4*a^2*d)

________________________________________________________________________________________

Maple [A]  time = 0.026, size = 68, normalized size = 1.3 \begin{align*} -{\frac{1}{d{a}^{2} \left ( 1+\sec \left ( dx+c \right ) \right ) }}+2\,{\frac{\ln \left ( 1+\sec \left ( dx+c \right ) \right ) }{d{a}^{2}}}-{\frac{1}{d{a}^{2}\sec \left ( dx+c \right ) }}-2\,{\frac{\ln \left ( \sec \left ( dx+c \right ) \right ) }{d{a}^{2}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(d*x+c)/(a+a*sec(d*x+c))^2,x)

[Out]

-1/d/a^2/(1+sec(d*x+c))+2/d/a^2*ln(1+sec(d*x+c))-1/d/a^2/sec(d*x+c)-2/d/a^2*ln(sec(d*x+c))

________________________________________________________________________________________

Maxima [A]  time = 1.00639, size = 62, normalized size = 1.19 \begin{align*} \frac{\frac{1}{a^{2} \cos \left (d x + c\right ) + a^{2}} - \frac{\cos \left (d x + c\right )}{a^{2}} + \frac{2 \, \log \left (\cos \left (d x + c\right ) + 1\right )}{a^{2}}}{d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)/(a+a*sec(d*x+c))^2,x, algorithm="maxima")

[Out]

(1/(a^2*cos(d*x + c) + a^2) - cos(d*x + c)/a^2 + 2*log(cos(d*x + c) + 1)/a^2)/d

________________________________________________________________________________________

Fricas [A]  time = 1.72558, size = 159, normalized size = 3.06 \begin{align*} -\frac{\cos \left (d x + c\right )^{2} - 2 \,{\left (\cos \left (d x + c\right ) + 1\right )} \log \left (\frac{1}{2} \, \cos \left (d x + c\right ) + \frac{1}{2}\right ) + \cos \left (d x + c\right ) - 1}{a^{2} d \cos \left (d x + c\right ) + a^{2} d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)/(a+a*sec(d*x+c))^2,x, algorithm="fricas")

[Out]

-(cos(d*x + c)^2 - 2*(cos(d*x + c) + 1)*log(1/2*cos(d*x + c) + 1/2) + cos(d*x + c) - 1)/(a^2*d*cos(d*x + c) +
a^2*d)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \frac{\int \frac{\sin{\left (c + d x \right )}}{\sec ^{2}{\left (c + d x \right )} + 2 \sec{\left (c + d x \right )} + 1}\, dx}{a^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)/(a+a*sec(d*x+c))**2,x)

[Out]

Integral(sin(c + d*x)/(sec(c + d*x)**2 + 2*sec(c + d*x) + 1), x)/a**2

________________________________________________________________________________________

Giac [A]  time = 1.30162, size = 70, normalized size = 1.35 \begin{align*} -\frac{\cos \left (d x + c\right )}{a^{2} d} + \frac{2 \, \log \left ({\left | -\cos \left (d x + c\right ) - 1 \right |}\right )}{a^{2} d} + \frac{1}{a^{2} d{\left (\cos \left (d x + c\right ) + 1\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)/(a+a*sec(d*x+c))^2,x, algorithm="giac")

[Out]

-cos(d*x + c)/(a^2*d) + 2*log(abs(-cos(d*x + c) - 1))/(a^2*d) + 1/(a^2*d*(cos(d*x + c) + 1))